Hi all, |
Re: how to call an existing JAVA/C api or console command in DXL |
Re: how to call an existing JAVA/C api or console command in DXL 2. Leveraging an existing C API from DXL is impossible without very dirty hacks. Interfacing a Java API? Well maybe in "DOORS Next Generation ...". What you always can do is create a COM server in some language of your choice, which will then interface to your APIs. You can then use the COM server to interface to your applications. This can be done quickly, however you need some experience in COM server programming to "get it right". Regards, Mathias Mathias Mamsch, IT-QBase GmbH, Consultant for Requirement Engineering and D00RS Attachments attachment_14702321_Shell.inc |
Re: how to call an existing JAVA/C api or console command in DXL Mathias Mamsch - Thu Nov 10 08:28:32 EST 2011 Mathias Mamsch, IT-QBase GmbH, Consultant for Requirement Engineering and D00RS Hello, It would be neat if the shell/command windows can be hid. Thanks Jester |
Re: how to call an existing JAVA/C api or console command in DXL jester76 - Thu Oct 24 20:40:38 EDT 2013 Hello, It would be neat if the shell/command windows can be hid. Thanks Jester Please note that there are NO shell windows appearing, when using shell.inc to start Notepad. If there is a shell window appearing when you are using shell.inc to run something it may be, that you are running a console application (that is by itself creating a console to output stuff). The normal OS start process functions do not suppress the console of console applications when you run them. For this you need to start your console application over a separate tool, that will block the console. Details on your favorite search engine, e.g. see here: http://www.codeproject.com/Articles/2537/Running-console-applications-silently Alternatively if you are running a tool, that you created yourself, just link it as a non console application. Regards, Mathias |
Re: how to call an existing JAVA/C api or console command in DXL Mathias Mamsch - Fri Oct 25 06:32:41 EDT 2013 Please note that there are NO shell windows appearing, when using shell.inc to start Notepad. If there is a shell window appearing when you are using shell.inc to run something it may be, that you are running a console application (that is by itself creating a console to output stuff). The normal OS start process functions do not suppress the console of console applications when you run them. For this you need to start your console application over a separate tool, that will block the console. Details on your favorite search engine, e.g. see here: http://www.codeproject.com/Articles/2537/Running-console-applications-silently Alternatively if you are running a tool, that you created yourself, just link it as a non console application. Regards, Mathias It seems the WScript OLE object also allows you to start an application without a window. So in this case, you have to use the "Run" method instead of the exec method and pass 0 (hide) as a second argument. But in this case you cannot get the output of the process or terminate it, so that is something that cannot be patched in shell.inc. So something like this should get you started:
Regards, Mathias |
Re: how to call an existing JAVA/C api or console command in DXL Mathias Mamsch - Fri Oct 25 06:51:26 EDT 2013 It seems the WScript OLE object also allows you to start an application without a window. So in this case, you have to use the "Run" method instead of the exec method and pass 0 (hide) as a second argument. But in this case you cannot get the output of the process or terminate it, so that is something that cannot be patched in shell.inc. So something like this should get you started:
Regards, Mathias when I run the above code I get the following error any ideas what maybe the cause?:
OLE problem: , OLE error code: -2147024891 |